package weekend2;

public class Duck extends Animal implements LayEggs,Swim{
    @Override
    void eat() {
        System.out.println(age+"岁的，"+color+"色的鸭鸭"+name+"正在吃小鱼");
    }

    @Override
    public void layEggs() {
        System.out.println(age+"岁的，"+color+"色的鸭鸭"+name+"正在下蛋");
    }

    @Override
    public void swim() {
        System.out.println(age+"岁的，"+color+"色的鸭鸭"+name+"正在游泳");
    }
    Duck(String name,int age,String color){
        super(name,age,color);
    }
}
